﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Dialog.Master" AutoEventWireup="true"
    CodeBehind="PaymentMachineAccountInfoEdit.aspx.cs" Inherits="NetDon.OA.Portal.Finance.PaymentMachineAccountInfoEdit" %>

<%@ Register Src="../Controls/RequiredMark.ascx" TagName="RequiredMark" TagPrefix="uc1" %>
<%@ Register TagPrefix="uc2" TagName="ComanyDepartment" Src="~/Components/ProvinceCity.ascx" %>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <asp:Panel ID="panelBasic" runat="server" DefaultButton="btnSave">
        <table border="0" cellpadding="0" cellspacing="0" width="100%">
            <tr>
                <td>
                    <NetDon:FormPanel ID="FormPanelPaymentOrIncome" runat="server" CaptionAlign="NotSet"
                        RepeatColumns="2">
                        <Items>
                            <NetDon:FormItem FullRow="True" HeaderVisible="False">
                                <ContentTemplate>
                                    <asp:Literal ID="Literal4" runat="server" Text="台帐类型"></asp:Literal>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="请选择" Key="FormItemBusinessTypeEditMode">
                                <ContentTemplate>
                                    <asp:RadioButton runat="server" AutoPostBack="True" Text="收入" GroupName="MachineAccount"
                                        ID="radioMachineAccountIncome" OnCheckedChanged="radioMachineAccount_CheckedChanged" />
                                    <asp:RadioButton runat="server" AutoPostBack="True" Text="支出" GroupName="MachineAccount"
                                        ID="radioMachineAccountPayment" OnCheckedChanged="radioMachineAccount_CheckedChanged" />
                                    <uc1:RequiredMark ID="RequiredMark_1" runat="server" />
                                </ContentTemplate>
                            </NetDon:FormItem>
                        </Items>
                    </NetDon:FormPanel>
                    <NetDon:FormPanel ID="FormPanelPayment" runat="server" CaptionAlign="NotSet" RepeatColumns="2">
                        <Items>
                            <NetDon:FormItem FullRow="True" HeaderVisible="False">
                                <ContentTemplate>
                                    <asp:Literal ID="Literal2" runat="server" Text="付款信息"></asp:Literal>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="订单编号">
                                <ContentTemplate>
                                    <asp:Label runat="server" ID="txtOrderCode">	</asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="线路分类">
                                <ContentTemplate>
                                    <asp:Label runat="server" ID="lblRouteName">	</asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="运输计划号">
                                <ContentTemplate>
                                    <asp:Label ID="lblTransporationPlanCode" runat="server"></asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="应付运费（成本）(￥)">
                                <ContentTemplate>
                                    <asp:Label ID="txtDueShippingCost" Text='<%#Convert.ToDecimal(Eval("DueShippingCost")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="已付运费(￥)">
                                <ContentTemplate>
                                    <asp:Label ID="txtPaidShippingCost" Text='<%#Convert.ToDecimal(Eval("PaidShippingCost")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="待付运费(￥)" ColumnSpan="2">
                                <ContentTemplate>
                                    <asp:Label ID="txtPendingShippingCost" Text='<%#Convert.ToDecimal(Eval("PendingShippingCost")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="付款日期">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtPaymentOrIncomeDate" Text='<%#Eval("PaymentOrIncomeDate") != null ? ((DateTime)Eval("PaymentOrIncomeDate")).ToString("yyyy-MM-dd") : ""%>'
                                        runat="server"></asp:TextBox>
                                    <uc1:RequiredMark ID="RequiredMark4" runat="server" />
                                    <asp:CalendarExtender ID="txtReceivingOrderDateCalendarExtender1" runat="server"
                                        Animated="False" Enabled="True" FirstDayOfWeek="Sunday" TargetControlID="txtPaymentOrIncomeDate"
                                        Format="yyyy-MM-dd">
                                    </asp:CalendarExtender>
                                    <asp:CustomValidator ID="txtReceivingOrderDateCustomValidator1" ClientValidationFunction="validateDateText"
                                        runat="server" ErrorMessage="付款日期无效." Display="None" ControlToValidate="txtPaymentOrIncomeDate"
                                        OnServerValidate="DateValidator_ServerValidate"></asp:CustomValidator>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txtPaymentOrIncomeDate"
                                        Display="None" ErrorMessage="请输入付款日期" SetFocusOnError="True"></asp:RequiredFieldValidator>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="支出金额(￥)">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtToBePaidShippingCost" Text='<%#Convert.ToDecimal(Eval("TobePaidShippingCost")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                                    <uc1:RequiredMark ID="RequiredMark6" runat="server" />
                                    <NetDon:NumericEditExtender ID="NumericEditExtender1" runat="server" TargetControlID="txtToBePaidShippingCost"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="装卸费(￥)" ColumnSpan="2">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtGoodsUnloadingCost" Text='<%#Convert.ToDecimal(Eval("GoodsUnloadingCost")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                                 
                                    <NetDon:NumericEditExtender ID="NumericEditExtender3" runat="server" TargetControlID="txtGoodsUnloadingCost"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="工厂扣罚(￥)" ColumnSpan="2">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtOtherAmountFromManufactor" Text='<%#Convert.ToDecimal(Eval("OtherAmountFromManufactor")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                             
                                    <NetDon:NumericEditExtender ID="NumericEditExtender5" runat="server" TargetControlID="txtOtherAmountFromManufactor"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="付款方式">
                                <ContentTemplate>
                                    <asp:DropDownList ID="ddlPaymentMethod" DataSourceID="ddsPaymentMethod" AppendDataBoundItems="True"
                                        runat="server" DataTextField="Name" DataValueField="Value">
                                    </asp:DropDownList>
                                    <NetDon:DictionaryDataSource ID="ddsPaymentMethod" runat="server" CategoryName="付款方式"
                                        EmptyItemType="Select">
                                    </NetDon:DictionaryDataSource>
                                    <uc1:RequiredMark ID="RequiredMark8" runat="server" />
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator8" runat="server" ControlToValidate="ddlPaymentMethod"
                                        Display="None" ErrorMessage="请输入付款方式" SetFocusOnError="True"></asp:RequiredFieldValidator>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="扣罚司机金额(￥)" ColumnSpan="2">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtDeductionExceptionsAmount" Text='<%#Convert.ToDecimal(Eval("DeductionExceptionsAmount")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                              
                                    <NetDon:NumericEditExtender ID="NumericEditExtender6" runat="server" TargetControlID="txtDeductionExceptionsAmount"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="扣罚异常备注" ColumnSpan="2">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtDeductionExceptionsComments" runat="server" Text='<%#Bind("DeductionExceptionsComments") %>'
                                        Width="450px" TextMode="MultiLine" Height="100px"></asp:TextBox>
                                </ContentTemplate>
                            </NetDon:FormItem>
                        </Items>
                    </NetDon:FormPanel>
                    <NetDon:FormPanel ID="FormPanelIncome" runat="server" CaptionAlign="NotSet" RepeatColumns="2">
                        <Items>
                            <NetDon:FormItem FullRow="True" HeaderVisible="False">
                                <ContentTemplate>
                                    <asp:Literal ID="Literal1" runat="server" Text="收入信息"></asp:Literal>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="订单编号">
                                <ContentTemplate>
                                    <asp:Label runat="server" ID="txtOrderCode1" Text='<%# Eval("OrderCode") %>'>	</asp:Label>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="收入日期">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtPaymentOrIncomeDate1" Text='<%#Eval("PaymentOrIncomeDate") != null ? ((DateTime)Eval("PaymentOrIncomeDate")).ToString("yyyy-MM-dd") : ""%>'
                                        runat="server"></asp:TextBox>
                                    <uc1:RequiredMark ID="RequiredMark7" runat="server" />
                                    <asp:CalendarExtender ID="CalendarExtender1" runat="server" Animated="False" Enabled="True"
                                        FirstDayOfWeek="Sunday" TargetControlID="txtPaymentOrIncomeDate1" Format="yyyy-MM-dd">
                                    </asp:CalendarExtender>
                                    <asp:CustomValidator ID="CustomValidator1" ClientValidationFunction="validateDateText"
                                        runat="server" ErrorMessage="收入日期无效." Display="None" ControlToValidate="txtPaymentOrIncomeDate1"
                                        OnServerValidate="DateValidator_ServerValidate"></asp:CustomValidator>
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtPaymentOrIncomeDate1"
                                        Display="None" ErrorMessage="请输入收入日期" SetFocusOnError="True"></asp:RequiredFieldValidator>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="收入方式">
                                <ContentTemplate>
                                    <asp:DropDownList ID="ddlIncomeType" DataSourceID="ddsIncomeType" AppendDataBoundItems="True"
                                        runat="server" DataTextField="Name" DataValueField="Value">
                                    </asp:DropDownList>
                                    <NetDon:DictionaryDataSource ID="ddsIncomeType" runat="server" CategoryName="收入方式"
                                        EmptyItemType="Select">
                                    </NetDon:DictionaryDataSource>
                                    <uc1:RequiredMark ID="RequiredMark11" runat="server" />
                                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="ddlIncomeType"
                                        Display="None" ErrorMessage="请输入收入方式" SetFocusOnError="True"></asp:RequiredFieldValidator>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="收入(￥)">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtIncomeAmount" Text='<%#Convert.ToDecimal(Eval("IncomeAmount")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                                    <NetDon:NumericEditExtender ID="NumericEditExtender7" runat="server" TargetControlID="txtIncomeAmount"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                            <NetDon:FormItem HeaderText="其它收入(￥)">
                                <ContentTemplate>
                                    <asp:TextBox ID="txtOtherIncome" Text='<%#Convert.ToDecimal(Eval("OtherIncome")).ToString("#,###.00")%>'
                                        runat="server" SkinID="Text80" Style="text-align: right"></asp:TextBox>
                                    <NetDon:NumericEditExtender ID="NumericEditExtender8" runat="server" TargetControlID="txtOtherIncome"
                                        DataMode="Double">
                                    </NetDon:NumericEditExtender>
                                </ContentTemplate>
                            </NetDon:FormItem>
                        </Items>
                    </NetDon:FormPanel>
                </td>
            </tr>
            <tr>
                <td style="padding-left: 150px">
                    <asp:Button ID="btnSave" runat="server" SkinID="Button80" Text="保存" OnClick="btnSave_Click" />
                    <asp:Button ID="btnCancel" runat="server" SkinID="Button80" Text="取消" CausesValidation="false" />
                    <NetDon:ValidationSummary ID="ValidationSummary1" runat="server" ShowMessageBox="true"
                        ShowSummary="false" />
                </td>
            </tr>
        </table>
    </asp:Panel>
</asp:Content>
